display: Add vfunc for get_monitor_at_window
authorOlivier Fourdan <ofourdan@redhat.com>
Tue, 17 May 2016 11:09:23 +0000 (13:09 +0200)
committerOlivier Fourdan <ofourdan@redhat.com>
Wed, 18 May 2016 17:07:27 +0000 (19:07 +0200)
commitd288a134a427e5728d230404c6a56fc9397b45d9
treedf9aab5b3614c2e395de16af5f514eebf2d07e82
parentfa9f22eec4fafd9a484864f45e0ac26ba584f0ef
display: Add vfunc for get_monitor_at_window

Some backends (namely Wayland) do not support global coordinates so
using the window position to determine the monitor will always fail on
such backends.

In such cases, the backend itself might be better suited to identify
the monitor a given window resides on.

Add a vfunc get_monitor_at_window() to the display class so that we can
use the backend to retrieve the monitor, if the backend implements it.

https://bugzilla.gnome.org/show_bug.cgi?id=766566
gdk/gdkdisplay.c
gdk/gdkdisplayprivate.h